<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>SC2API: include/sc2api/sc2_interfaces.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="SC2-Logo.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">SC2API
   </div>
   <div id="projectbrief">An API for AI for StarCraft II</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_3d0dfd3160b31ffa512c49330ac8d646.html">sc2api</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#enum-members">Enumerations</a>  </div>
  <div class="headertitle">
<div class="title">sc2_interfaces.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>A set of public facing interfaces used to query game state.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &quot;<a class="el" href="sc2__common_8h_source.html">sc2api/sc2_common.h</a>&quot;</code><br />
<code>#include &quot;sc2api/sc2_action.h&quot;</code><br />
<code>#include &quot;<a class="el" href="sc2__unit_8h_source.html">sc2api/sc2_unit.h</a>&quot;</code><br />
<code>#include &quot;sc2api/sc2_data.h&quot;</code><br />
<code>#include &lt;vector&gt;</code><br />
</div>
<p><a href="sc2__interfaces_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Classes</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsc2_1_1_observation_interface.html">sc2::ObservationInterface</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">The <a class="el" href="classsc2_1_1_observation_interface.html" title="The ObservationInterface reflects the current state of the game. Guaranteed to be valid when OnGameSt...">ObservationInterface</a> reflects the current state of the game. Guaranteed to be valid when OnGameStart or OnStep is called.  <a href="classsc2_1_1_observation_interface.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsc2_1_1_query_interface.html">sc2::QueryInterface</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_query_interface_1_1_pathing_query.html">sc2::QueryInterface::PathingQuery</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsc2_1_1_query_interface_1_1_placement_query.html">sc2::QueryInterface::PlacementQuery</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsc2_1_1_action_interface.html">sc2::ActionInterface</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsc2_1_1_action_feature_layer_interface.html">sc2::ActionFeatureLayerInterface</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsc2_1_1_debug_interface.html">sc2::DebugInterface</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:a5cc3d9751182ccd2b085f3e272bcc88b"><td class="memItemLeft" align="right" valign="top">typedef std::function&lt; bool(const Unit &amp;unit)&gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sc2__interfaces_8h.html#a5cc3d9751182ccd2b085f3e272bcc88b">sc2::Filter</a></td></tr>
<tr class="separator:a5cc3d9751182ccd2b085f3e272bcc88b"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:afc6e05d736b6c20a5d335f4959912af7"><td class="memItemLeft" align="right" valign="top"><a id="afc6e05d736b6c20a5d335f4959912af7"></a>enum &#160;</td><td class="memItemRight" valign="bottom"><b>Visibility</b> { <b>Hidden</b> = 0, 
<b>Fogged</b> = 1, 
<b>Visible</b> = 2, 
<b>FullHidden</b> = 3
 }</td></tr>
<tr class="separator:afc6e05d736b6c20a5d335f4959912af7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>A set of public facing interfaces used to query game state. </p>
<p>Each function in this class is pure virtual but is not intended for a user of the API to overwrite. An implementation file that utilizes this interface will be responsible for its definition and should be of little concern to the consumer. </p>
</div><h2 class="groupheader">Typedef Documentation</h2>
<a id="file_a5cc3d9751182ccd2b085f3e272bcc88b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#file_a5cc3d9751182ccd2b085f3e272bcc88b">&#9670;&nbsp;</a></span>Filter</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef std::function&lt;bool(const Unit&amp; unit)&gt; <a class="el" href="sc2__interfaces_8h.html#a5cc3d9751182ccd2b085f3e272bcc88b">sc2::Filter</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Used to filter out units when querying. You can use this filter to get all full health units, for example. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">unit</td><td>The unit in question to filter. </td></tr>
    <tr><td class="paramname">observation</td><td>The interface for querying game state to determine whether the unit should be filtered or not. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Whether or not to filter the unit in or out of the list. true will add the unit, false will leave it out of the list. </dd></dl>
<dl class="section see"><dt>See also</dt><dd>GetUnits() </dd></dl>

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.13
</small></address>
</body>
</html>
